import json

with open("./replace/main.json", "r", encoding="utf-8") as f:
    d: dict = json.load(f)

with open("./en/main.js", "r", encoding="utf-8") as r:
    EN = r.read()

with open("./main.js", "a+", encoding="utf-8") as w:
    for key in d.keys():
        value = d[key]
        EN = EN.replace(key, value)
    w.write(EN)
